package com.example.tencentdemo.config;

import com.example.tencentdemo.controller.adminChannel;
import com.example.tencentdemo.controller.chatChannel;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.socket.server.standard.ServerEndpointExporter;


@Configuration
public class WebSocketConfiguration {

    @Bean
    public ServerEndpointExporter serverEndpointExporter (){

        ServerEndpointExporter exporter = new ServerEndpointExporter();

        exporter.setAnnotatedEndpointClasses(chatChannel.class, adminChannel.class);

        return exporter;
    }
}